---
title: Slide Over
description: A window overlaid on either the primary window or another dialog window, rendering the content underneath inert.
featured: true
component: true
links:
  doc: https://www.radix-ui.com/docs/primitives/components/dialog
  api: https://www.radix-ui.com/docs/primitives/components/dialog#api-reference
---

<ComponentPreview
  name="slide-over-demo"
  description="A sliding panel for editing or displaying extra details."
  styleSwitch={true}
  button="copy"
  dots={false}
/>

## Installation

<Tabs defaultValue="cli">

<TabsList>
  <TabsTrigger value="cli">CLI</TabsTrigger>
  <TabsTrigger value="manual">Manual</TabsTrigger>
</TabsList>
<TabsContent value="cli">

```bash
npx nyxb@latest add slide-over
```

</TabsContent>

<TabsContent value="manual">

<Steps>

<Step>Install the following dependencies:</Step>

```bash
 @radix-ui/react-dialog
```

<Step>Copy and paste the following code into your project.</Step>

<ComponentSource name="slide-over" />

<Step>Update the import paths to match your project setup.</Step>

</Steps>

</TabsContent>

</Tabs>

## Usage

```tsx
import {
  SlideOver,
  SlideOverContent,
  SlideOverDescription,
  SlideOverHeader,
  SlideOverTitle,
  SlideOverTrigger,
} from "~/components/ui/slide-over"
```

```tsx
<SlideOver>
  <SlideOverTrigger>Open</SlideOverTrigger>
  <SlideOverContent>
    <SlideOverHeader>
      <SlideOverTitle>Are you absolutely sure?</SlideOverTitle>
      <SlideOverDescription>
        This action cannot be undone. This will permanently delete your account
        and remove your data from our servers.
      </SlideOverDescription>
    </SlideOverHeader>
  </SlideOverContent>
</SlideOver>
```

## Examples

### Custom close button

<ComponentPreview
   name="slide-over-close-button"
   styleSwitch={true}
   button="copy"
   dots={false}
 />
